package com.fangngng.pushall.mapper;

import com.fangngng.pushall.entity.Category;
import com.fangngng.pushall.entity.Topic;
import com.fangngng.pushall.entity.UserSubcribe;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;
import tk.mybatis.mapper.common.BaseMapper;

import java.util.List;

@Repository
@Mapper
public interface UserSubcribeMapper extends BaseMapper<UserSubcribe> {

    Topic findByUserIdAndTopicId(@Param("userId") Integer userId, @Param("topicId") Integer topicId);

    List<UserSubcribe> findByTopicId(@Param("topicId") Integer topicId);
}